﻿<%@ Page Language="C#" Inherits="PageBase" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>管理后台</title>
    <link href="../js/themes/default/easyui.css" rel="stylesheet" type="text/css" />
    <link href="../js/themes/icon.css" rel="stylesheet" type="text/css" />
    <link href="../css/default.css" rel="stylesheet" type="text/css" />

    <script src="../js/jquery-1.4.4.min.js" type="text/javascript"></script>

    <script src="../js/jquery.easyui.min.js" type="text/javascript"></script>

    <script src="../js/locale/easyui-lang-zh_CN.js" type="text/javascript"></script>

    <script src="../js/common.js" type="text/javascript"></script>

    <script type="text/javascript" src="../js/index.js"> </script>

    <script type="text/javascript">
        var _menus = '';
        var me = {
            win_changepwd: null,
            win_changepwd_form: null
        };
        $(function() {
            pageInit();
        });
        function pageInit() {
            me.win_changepwd = $('#win_changepwd');
            me.win_changepwd_form = me.win_changepwd.find('#win_changepwd_form');

            $('#editpass').click(function() {
                me.win_changepwd.window('open');
            });

            $('#btnEp').click(function() {
                changePwd();
            });

            $('#btnCancel').click(function() {
                me.win_changepwd.window('close');
            })

            $('#loginOut').click(function() {
                $.messager.confirm('系统提示', '您确定要退出本次登录吗?', function(isOk) {
                    if (isOk) {
                        $.ajax({
                            url: '../ashx/LoginOut.ashx',
                            data: {},
                            success: function(returnData) {
                                if (returnData) {
                                    if (returnData.isOk == 1) {
                                        location.href = 'Login.aspx';
                                    } else {
                                        showError(returnData.message);
                                    }
                                }
                            }
                        });
                    }
                });
            })
        }

        //修改密码
        function changePwd() {
            if (me.win_changepwd_form.form('validate')) {
                $.ajax({
                    url: '../ashx/SysUser.ashx?Method=ChangePassword',
                    data: me.win_changepwd_form.serialize(),
                    success: function(returnData) {
                        if (returnData) {
                            if (returnData.isOk == 1) {
                                showInfo('恭喜，密码修改成功！<br>您的新密码为：' + me.win_changepwd_form.find("#NewPassword").val());
                                me.win_changepwd_form.form('clear');
                                me.win_changepwd.window('close');
                            } else {
                                showError(returnData.message);
                            }
                        }
                    }
                });
            }
        }

    </script>

</head>
<body class="easyui-layout" style="overflow-y: hidden" scroll="no">
    <noscript>
        <div style="position: absolute; z-index: 100000; height: 2046px; top: 0px; left: 0px; width: 100%; background: white; text-align: center;">
            <img src="../images/noscript.gif" alt='抱歉，请开启脚本支持！' />
        </div>
    </noscript>
    <div region="north" split="true" border="false" style="overflow: hidden; height: 30px; background: url(../images/layout-browser-hd-bg.gif) #7f99be repeat-x center 50%; line-height: 20px; color: #fff; font-family: Verdana, 微软雅黑,黑体">
        <span style="float: right; padding-right: 20px;" class="head">欢迎<a href="javascript:void(0)" id="editpass">修改密码</a> <a href="#" id="loginOut">安全退出</a></span> <span style="padding-left: 10px; font-size: 16px;">
            <img src="../images/blocks.gif" width="20" height="20" align="absmiddle" />【ＸＸＸ】应用实例</span>
    </div>
    <div region="south" split="true" style="height: 30px; background: #D2E0F2;">
        <div class="footer">
            
        </div>
    </div>
    <div region="west" hide="true" split="true" title="导航菜单" style="width: 180px;" id="west">
        <div id="nav" class="easyui-accordion" fit="true" border="false" title="导航内容">
        </div>
    </div>
    <div id="mainPanle" region="center" style="background: #eee; overflow-y: hidden">
        <div id="tabs" class="easyui-tabs" fit="true" border="false">
            <div title="欢迎使用" style="padding: 20px; overflow: hidden; color: red; display: block;">
                <div>
                    <h2>
                        火狐浏览器下开发，通过测试！</h2>
                </div>
              <%--  <h1 style="font-size: 24px;">
                    * 作者：张朋举 QQ：272797853</h1>
                <h1 style="font-size: 24px;">
                    * 广告：本人承接各类大中小型管理系统的软件的设计与开发，有需要的朋友联系我啦~~~~</h1>
                <h2>
                    火狐浏览器下开发，通过测试！</h2>--%>
            </div>
        </div>
    </div>
    <div id="win_changepwd" class="easyui-window" closed="true" title="修改密码" icon="icon-save" style="width: 350px; height: 200px; padding: 5px; background: #fafafa;">
        <div class="easyui-layout" fit="true">
            <div region="center" border="false" style="padding: 10px; background: #fff; border: 1px solid #ccc;">
                <form id="win_changepwd_form" name="win_changepwd_form" method="post">
                <table cellpadding="3" align="center">
                    <tr>
                        <td>
                            旧密码：
                        </td>
                        <td>
                            <input id="OldPassword" name="OldPassword" type="Password" class="easyui-validatebox" required="true" />
                        </td>
                    </tr>
                    <tr>
                        <td>
                            新密码：
                        </td>
                        <td>
                            <input id="NewPassword" name="NewPassword" type="Password" class="easyui-validatebox" required="true" />
                        </td>
                    </tr>
                    <tr>
                        <td>
                            确认密码：
                        </td>
                        <td>
                            <input id="NewPasswordRe" name="NewPasswordRe" type="Password" class="easyui-validatebox" required="true" validtype="equalTo['#NewPassword']" />
                        </td>
                    </tr>
                </table>
                </form>
            </div>
            <div region="south" border="false" style="text-align: center; height: 30px; line-height: 30px;">
                <a id="btnEp" class="easyui-linkbutton" icon="icon-ok" href="javascript:void(0)">确定</a> <a id="btnCancel" class="easyui-linkbutton" icon="icon-cancel" href="javascript:void(0)">关闭</a>
            </div>
        </div>
    </div>
    <div id="mm" class="easyui-menu" style="width: 150px;" title="多标签右键菜单">
        <div id="mm-tabupdate">
            刷新</div>
        <div class="menu-sep">
        </div>
        <div id="mm-tabclose">
            关闭</div>
        <div id="mm-tabcloseall">
            全部关闭</div>
        <div id="mm-tabcloseother">
            除此之外全部关闭</div>
        <div class="menu-sep">
        </div>
        <div id="mm-tabcloseright">
            当前页右侧全部关闭</div>
        <div id="mm-tabcloseleft">
            当前页左侧全部关闭</div>
        <div class="menu-sep">
        </div>
        <div id="mm-exit">
            退出</div>
    </div>
</body>
</html>
